package com.kitty.common.schedule.task;

import com.kitty.common.utils.SpringUtils;
import com.kitty.game.activity.service.time.XingGuanHandler;
import lombok.extern.slf4j.Slf4j;
import org.apache.commons.lang3.time.StopWatch;
import org.springframework.stereotype.Component;

@Component
@Slf4j
public class XingTask implements ScheduledOfTask {
    @Override
    public void execute() {
        StopWatch stopWatch = new StopWatch();
        stopWatch.start();
        SpringUtils.getBean(XingGuanHandler.class).flushXingGuanAfterServerStart();
        stopWatch.stop();
        log.info("刷新星官开始，用时{}毫秒", stopWatch.getTime());
    }

}
